#################################################
#    	   MAKEFILE FOR Docxcon Plugin		#
#						#
# Autor: Marek Szanyi				#
# Date:  25.3.2010				#
#						#
#################################################


# final product of this makefile
all: docxcon.shl

# compilator
CCC = g++

# compilator options
CFLAGS  = -O 

# include headers
INCLUDES = -I. -I../PComunicator/src/ -I../Zipios/src/ -I../Convertor/src/Plugin/ -I../xmlwrapp/include/

# linked libs
LIBS = -L../PComunicator/lib/ -lPComunicator -L../Zipios/lib/ -lZipios -lboost_filesystem -lboost_system -lpthread -lxml2 -lxslt -lz -lxsltwrapp -lxmlwrapp 
	   

# the server itself
docxcon.shl: entry.o Docxconv.o
	$(CCC) $(LIBS) -shared -fpic -static -o docxcon.shl entry.o Docxconv.o $(LIBS)

# server parts
entry.o:   ./src/entry.cpp 
	$(CCC) $(INCLUDES) $(CFLAGS) -c ./src/entry.cpp
		
Docxconv.o:  ./src/Docxconv.cpp ./src/Docxconv.h
	$(CCC) $(INCLUDES) $(CFLAGS) -c ./src/Docxconv.cpp

install: docxcon.shl
	cp docxcon.shl ./bin/docxcon.shl

	echo "******** INSTALATION AND STUFF DONE *************\n\n"
